<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>无标题文档</title>
<style>
div{width:200px;height:200px;background:red;border:5px solid #000;}
.box1{display:none;}
.box2{visibility:hidden;}
</style>
</head>
<body>
<div class="box1">box1</div>
<div class="box2">box2</div>
<div class="box3">box3</div>
<p>.box1{display:none;}直接不见了，文档位置也不见了</p>
<p>.box2{visibility:hidden;}隐身了，保留文档位置</p>
</body>
</html>
